#include <stdio.h>

int * Bubble_sort(int * arr,int len)
{
    for (int i = 0; i < len; i++)
    {
        for (int j = 0; j < len-1; j++)
        {
            if (*(arr+j)>*(arr+j+1))
            {
                int temp = *(arr+j+1) ;
                *(arr+j+1) = *(arr+j) ;
                *(arr+j) = temp ;
            }
            
        }
        
    }
    

}
void main()
{
    int arr[]={1,3,9,5,4,7,2};
    Bubble_sort(arr,7);
    for (int i = 0; i < 7; i++)
    {
        printf("%d ",arr[i]);
    }
    printf("\n");
}